'use strict';
module.exports = {
	/**
	 * XXXnameXXX
	 * @url admin/pages/files_mzgl/dy_djcx/kh/update 前端调用的url参数地址
	 * data 请求参数
	 * @param {String} params1  参数1
	 */
	main: async (event) => {
		let { data = {}, userInfo, util, filterResponse, originalParam } = event;
		let { customUtil, uniID, config, pubFun, vk, db, _ } = util;
		let { uid,_id,formdata } = data;
		let res = { code: 0, msg: "" };
		// 业务逻辑开始-----------------------------------------------------------
		// 参数验证结束
		let dbName = "dy_djcx"; // 表名
		// 执行 数据库 updateById 命令
		await vk.baseDao.updateById({
			dbName,
			id: _id,
			dataJson: {
				ma_app_id:formdata.ma_app_id,
				appsecret:formdata.appsecret,
				album_id:formdata.album_id,
				c:formdata.c,
				limit:formdata.limit,
				offset:formdata.offset,
				version:formdata.version,
			}
		});




		// 业务逻辑结束-----------------------------------------------------------
		return res;
	}
}
